<?php
/**
 * @package                Joomla.Site
 * @subpackage	Templates.beez_20
 * @copyright        Copyright (C) 2005 - 2012 Open Source Matters, Inc. All rights reserved.
 * @license                GNU General Public License version 2 or later; see LICENSE.txt
 */

// No direct access.
defined('_JEXEC') or die;

jimport('joomla.filesystem.file');

// check modules
$pageoption = JRequest::getVar('option');
$pageview = JRequest::getVar('view');
$isHome = ($pageoption=='com_content' and $pageview=='featured');
$isArticle = ($pageoption=='com_content' and $pageview=='article');
$isContact = ($pageoption=='com_contact');
$isCategory = ($pageoption=='com_content' and $pageview=='category');
$isGallery = ($pageoption=='com_phocagallery');
$isNewsletter = ($pageoption=='com_acymailing');
$showIntro	= ($this->countModules('introduction') or $this->countModules('intro-video-text-1') or $this->countModules('intro-video-text-2') or $this->countModules('intro-video-1') or $this->countModules('intro-video-2'));
$showSections			= ($this->countModules('section-1') or $this->countModules('section-2') or $this->countModules('section-3'));
$showright			= ($this->countModules('right-column'));
$showforms			= ($this->countModules('right-forms') and ($isCategory or $isContact));

$tplclass ='';
$wrapperid ='max-download-trial';
$tplid ='download-trial-tpl';
if ($isArticle) {
	$tplclass ='col-4 col-last';
}
if ($isArticle and $showright) {
	$tplclass ='tpl-left col-3 left-content';
}
if ($isCategory or $isContact or $isNewsletter) {
	$tplclass ='col-2';
}
if ($isContact) {
	$wrapperid ='max-contact';
	$tplid ='contact-tpl';
}
JHtml::_('behavior.framework', true);

// get params
$color				= $this->params->get('templatecolor');
$logo				= $this->params->get('logo');
$navposition		= $this->params->get('navposition');
$app				= JFactory::getApplication();
$doc				= JFactory::getDocument();
$templateparams		= $app->getTemplate(true)->params;
$templatepath       = $this->baseurl.'/templates/'.$this->template;

?>
<!DOCTYPE html>
<!--[if lt IE 7]>      <html class="no-js lt-ie9 lt-ie8 lt-ie7"> <![endif]-->
<!--[if IE 7]>         <html class="no-js lt-ie9 lt-ie8"> <![endif]-->
<!--[if IE 8]>         <html class="no-js lt-ie9"> <![endif]-->
<!--[if gt IE 8]><!--> <html class="no-js" xml:lang="<?php echo $this->language; ?>" lang="<?php echo $this->language; ?>" dir="<?php echo $this->direction; ?>"> <!--<![endif]-->
<head>
<jdoc:include type="head" />
<link rel="stylesheet" href="<?php echo $templatepath; ?>/src/css/style.css">
<!--[if lt IE 9]>
  <script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->
<!--[if gte IE 9]>
  <style type="text/css">
    .gradient {
       filter: none;
    }
  </style>
<![endif]-->
<script type="text/javascript" src="<?php echo $templatepath; ?>/src/js/jquery-1.8.3.min.js"></script>
<script src="<?php echo $templatepath; ?>/src/js/modernizr-2.6.2-respond-1.1.0.min.js"></script>

<script type="text/javascript">
jQuery(function() {
if( jQuery('#system-message dd ul li').length > 0) {
			jQuery('#alert').html(jQuery('#system-message dd ul li').html());
			jQuery('#backoverlay').show();
			jQuery('#show_popup').show();
		}
});	
</script>
<style>	
 	a {cursor:pointer;}
    .bg_alert{ width:275px; height:115px; background:url("<?php echo $this->baseurl ?>/templates/<?php echo $this->template ?>/img/bg_alert.png") no-repeat top left; margin:0px auto; padding:10px 0px 0px 78px; color:#000;}
    .m35l{ margin-left:35px;}
</style>
</head>

<body>
<div id="dialog" style="display:none; position: fixed; top: 10%; left: 35%; z-index:10002;"></div>
<div class="bg_alert" id="show_popup" style="font-size:13px; display:none; position: fixed; top: 35%; left: 50%; z-index:10003; margin-left:-140px;">
    <span id="f_focus" style="display:none;"></span>
    <div style="margin:0; padding-top:0px; min-height:75px;width:260px;" id="alert"></div>
    <div style="padding-left: 40px;"><a href="javascript:void(0);" onclick="close_popup();"><img src="<?php echo $templatepath; ?>/img/bt_luk.png" alt="" /></a></div>
</div>
<div style="display: none;position: fixed; top: 0;left: 0;width: 100%;height: 100%;background-color: #000000;z-index:10002;-moz-opacity: 0.8;opacity:.80;filter: alpha(opacity=80);" id="backoverlay"></div>	

<div class="max-container clearfix" id="max-header">
    <header class="header clearfix">
        <h2 class="logo"><a href="index.php">LJBYG</a></h2>
        <div class="soc-link clearfix">
            <a href="https://www.facebook.com/pages/ljbygdk/563933743639061" id="soc-facebook" target="_blank">Facebook</a>
			<a href="http://borsen.dk/konferencer/gazeller.html" target="_blank"><img src="images/Gazellevirksomhed.jpg" alt="" /></a>

        </div>
        <div class="clr"></div>
        <nav class="nav-wrapper clearfix">
			<jdoc:include type="modules" name="navigate" />
            
        </nav>
    </header>
</div>
<div class="max-container clearfix" id="<?php echo $isHome?"body-style1":"body-style2"; ?>">
	<div class="wrapper">
		<?php if($this->countModules('slide')): ?>
		<div class="slider-wrapper clearfix">
			<jdoc:include type="modules" name="slide" />
		</div>
		<?php endif; ?>
		<!-- HOME TEMPLATE -->
		<?php if($isHome): ?>
		<div class="bd-content clearfix" id="home-page">
			<?php if($this->countModules('wc-left') or $this->countModules('wc-right')): ?>
			<div class="welcome-wrapper clearfix">
				<div class="wc-left">
					<jdoc:include type="modules" name="wc-left" />
				</div>
				<div class="wc-right">
					<jdoc:include type="modules" name="wc-right" />
				</div>
			</div>
			<?php endif; ?>
			<?php if($this->countModules('partners')): ?>
			<div class="list-partner clearfix">
				<jdoc:include type="modules" name="partners" />
			</div>
			<?php endif; ?>
		</div>
		<!-- GALLERY TEMPLATE -->
		<?php elseif($isGallery): ?>
		<div class="bd-content gal-tpl clearfix" id="gallery-page">
			<div class="breadcum clearfix">
				<jdoc:include type="modules" name="breadcrumbs" />
			</div>
			<jdoc:include type="message" />
			<jdoc:include type="component" />
		</div>
		<!-- DEFAULT TEMPLATE -->
		<?php else: ?>
		<div class="bd-content clearfix" id="home-page">
			<div class="breadcum clearfix">
				<jdoc:include type="modules" name="breadcrumbs" />
				
			</div>
			<div class="tpl-left">
				<div class="box-img">
					<jdoc:include type="modules" name="banner-right" />
				</div>
				<div class="box-logo">
					<jdoc:include type="modules" name="referencer" />
				</div>
			</div>
			<div class="tpl-right">
				<jdoc:include type="message" />
				<div class="box-content">
					<jdoc:include type="component" />
				</div>
			</div>
		</div>
		<?php endif; ?>
	</div>
</div>
<div class="wrapper">
	<footer class="footer clearfix">
		<jdoc:include type="modules" name="footer" />
	</footer>
</div>

<script type="text/javascript" src="<?php echo $templatepath; ?>/src/js/jquery.easing.js"></script>
<script type="text/javascript" src="<?php echo $templatepath; ?>/src/js/jquery.cycle2.min.js"></script>
<script type="text/javascript" src="<?php echo $templatepath; ?>/src/js/jquery.carouFredSel-6.2.0-packed.js"></script>
<script type="text/javascript" src="<?php echo $templatepath; ?>/src/js/jquery.inputToggle.min.js"></script>
<script type="text/javascript" src="<?php echo $templatepath; ?>/src/js/jquery.validate.js"></script>
<script type="text/javascript" src="<?php echo $templatepath; ?>/src/js/init.js"></script>
<jdoc:include type="modules" name="debug" />
</body>
</html>
